<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core">

    <ui:composition template="/template.xhtml">
        <ui:define name="title">
            <h:outputText value="#{bundle.CreateClienteTitle}"></h:outputText>
        </ui:define>
        <ui:define name="body">
            <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputLabel value="#{bundle.CreateClienteLabel_id}" for="id" />
                    <h:inputText id="id" value="#{clienteController.selected.id}" title="#{bundle.CreateClienteTitle_id}" required="true" requiredMessage="#{bundle.CreateClienteRequiredMessage_id}"/>
                    <h:outputLabel value="#{bundle.CreateClienteLabel_enderecoLogradouro}" for="enderecoLogradouro" />
                    <h:inputText id="enderecoLogradouro" value="#{clienteController.selected.enderecoLogradouro}" title="#{bundle.CreateClienteTitle_enderecoLogradouro}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_enderecoNumero}" for="enderecoNumero" />
                    <h:inputText id="enderecoNumero" value="#{clienteController.selected.enderecoNumero}" title="#{bundle.CreateClienteTitle_enderecoNumero}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_enderecoComplemento}" for="enderecoComplemento" />
                    <h:inputText id="enderecoComplemento" value="#{clienteController.selected.enderecoComplemento}" title="#{bundle.CreateClienteTitle_enderecoComplemento}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_enderecoBairro}" for="enderecoBairro" />
                    <h:inputText id="enderecoBairro" value="#{clienteController.selected.enderecoBairro}" title="#{bundle.CreateClienteTitle_enderecoBairro}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_enderecoCep}" for="enderecoCep" />
                    <h:inputText id="enderecoCep" value="#{clienteController.selected.enderecoCep}" title="#{bundle.CreateClienteTitle_enderecoCep}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_enderecoCidade}" for="enderecoCidade" />
                    <h:inputText id="enderecoCidade" value="#{clienteController.selected.enderecoCidade}" title="#{bundle.CreateClienteTitle_enderecoCidade}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_enderecoUf}" for="enderecoUf" />
                    <h:inputText id="enderecoUf" value="#{clienteController.selected.enderecoUf}" title="#{bundle.CreateClienteTitle_enderecoUf}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_telefoneCelular}" for="telefoneCelular" />
                    <h:inputText id="telefoneCelular" value="#{clienteController.selected.telefoneCelular}" title="#{bundle.CreateClienteTitle_telefoneCelular}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_telefoneResidencial}" for="telefoneResidencial" />
                    <h:inputText id="telefoneResidencial" value="#{clienteController.selected.telefoneResidencial}" title="#{bundle.CreateClienteTitle_telefoneResidencial}" />
                    <h:outputLabel value="#{bundle.CreateClienteLabel_telefoneComercial}" for="telefoneComercial" />
                    <h:inputText id="telefoneComercial" value="#{clienteController.selected.telefoneComercial}" title="#{bundle.CreateClienteTitle_telefoneComercial}" />
                </h:panelGrid>
                <br />
                <h:commandLink action="#{clienteController.create}" value="#{bundle.CreateClienteSaveLink}" />
                <br />
                <br />
                <h:commandLink action="#{clienteController.prepareList}" value="#{bundle.CreateClienteShowAllLink}" immediate="true"/>
                <br />
                <br />
                <h:link outcome="/index" value="#{bundle.CreateClienteIndexLink}"/>
            </h:form>
        </ui:define>
    </ui:composition>

</html>
